<template>
  <div class="home-recommend">
    <div class="top">
      <div class="top-left">
        <span>{{ props.title }}</span>
        <span>{{ props.subTitle }}</span>
      </div>
      <div class="top-right">
        <slot name="top-right"></slot>
      </div>
    </div>
    <div class="body">
      <slot></slot>
    </div>
  </div>
</template>

<script lang="ts"
        setup>
let props = defineProps<{
  title: string,
  subTitle?: string
}>()
</script>

<style lang="less"
       scoped>
.home-recommend {
  padding-bottom: 20px;

  .top {
    padding: 40px 0;
    display: flex;
    justify-content: space-between;

    .top-left {
      span:nth-of-type(1) {
        font-size: 32px;
        height: 35px;
        line-height: 35px;
      }

      span:nth-of-type(2) {
        font-size: 16px;
        color: #999;
        margin-left: 20px;
      }
    }

    .top-right {
      display: flex;
      align-items: flex-end;
    }
  }

  .body {
    display: flex;
    justify-content: space-evenly;
  }
}
</style>